using I2.Loc;

public class MarketComsumableInfoPanel : MarketProductInfoPanel
{
	public UILabel damageCount;

	public UILabel areaCount;

	public UISprite damageTypeSprite;

	public UILabel damageTypeLabel;

	public UILabel grenadesCount;

	public override void SetInfo(Product product, bool setUpgrades, bool needComparison = true)
	{
		currentProduct = product;
		base.SetInfo(product, setUpgrades);
		ProductComsumable productComsumable = ((!needComparison) ? product : MarketControllerUI.instance.selectedProduct) as ProductComsumable;
		damageCount.text = productComsumable.damage.ToString();
		areaCount.text = productComsumable.area.ToString();
		damageTypeSprite.spriteName = "DamageType_" + productComsumable.damageType;
		damageTypeLabel.text = ScriptLocalization.Get("Market/DamageType_" + productComsumable.damageType);
		if ((bool)grenadesCount)
		{
			grenadesCount.text = productComsumable.Count.ToString();
		}
		SetTitleLocalization();
		SetDescriptionLocalization();
		if (setUpgrades)
		{
			SetUpgrades();
		}
		else
		{
			SelectUpgradeButton();
		}
	}
}
